﻿using UnityEngine;
using System.Collections;

public class KillSelf : MonoBehaviour {
	int timer=0;
	ParticleSystem tst;
	// Use this for initialization
	void Start () {
		tst =this.GetComponent<ParticleSystem>();
	}
	
	// Update is called once per frame
	void Update () {
		if(timer++>1000){
			if(tst.particleCount==0)
				Destroy (gameObject);
		}
	}
}
